<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ include file="../includes/common.jsp" %>

<c:choose>

<c:when test="${pageCount > 0}">

	<c:if test="${not empty message}"><c:if test="${not empty message}"><div class="notification">${message}</div></c:if></c:if>
	
	<form action="${scriptPath}" id="listForm">
	<input type="hidden" name="action" value="exam.list" />
	
	<jsp:include page="exam.list-toolbar.jsp"></jsp:include>
	<jsp:include page="exam.list-nav.jsp"></jsp:include>
	
	<table>
	<tr>
		<th width="20px">&nbsp;</th>
		<th>Kì thi</th>
		<th>Đề</th>
		<th>Lớp</th>
		<th>Ngày thi</th>
	</tr>
	<c:forEach items="${exams}" var="exam">
		<tr>
			<td><input type="checkbox" name="el_exams" value="${exam.id}"></input></td>
			<td><a href="${scriptPath}?action=exam.view&ev_id=${exam.id}">${exam.name}</a></td>
			<td>${exam.test.name}</td>
			<td>${exam.clazz}</td>
			<td>${u:formatDate(exam.date)}</td>
		</tr>
	</c:forEach>
	<tr>
	</tr>
	</table>
	
	<jsp:include page="exam.list-nav.jsp"></jsp:include>
	<jsp:include page="exam.list-toolbar.jsp"></jsp:include>
	
	</form>
    
</c:when>

<c:otherwise>
    <div class="empty-notif">
        Chưa có dữ liệu
    </div>
</c:otherwise>

</c:choose>
	